﻿using Sustainalytics.LongRunningTaskManager.Interface;
using System;

namespace Sustainalytics.LongRunningTaskManager.Tests
{
    public class MyTaskFileOnDisk : MyTaskBase
    {
        public static LongRunningTaskFileOnDiskResult ReturnValue
        {
            get
            {
                return new LongRunningTaskFileOnDiskResult
                    {
                        ContentLength = 3,
                        FileName = "file.txt",
                        FilePath = string.Concat(Environment.CurrentDirectory, @"\TestFiles\file.txt"),
                        MimeType = "application/octet-stream"
                    };
            }
        }

        public override LongRunningTaskTypeEnum Type
        {
            get { return (LongRunningTaskTypeEnum)1005; }
        }

        public override object Start(LongRunningTaskContext context)
        {
            base.Start(context);

            return ReturnValue;
        }
    }
}
